﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="IncidentManageLog.aspx.cs" Inherits="H2.NET.Web.Workflow.Workflow.IncidentManageLog" %>

<%@ Register src="../UserControls/Pager.ascx" tagname="Pager" tagprefix="uc1" %>

<script type="text/javascript">
    function ExportExel() {
        var process = $("#processName").val();
        var from = $("#form").val();
        var to = $("#to").val();
        var status = $("#status").val();
        var form = "<form action='Workflow/IncidentManageLog.aspx?action=ExportExel' method='post'>"
           +"<input type='hidden' name='Process' value='" + process + "'>"
           + "<input type='hidden' name='From' value='" + from + "'>"
           + "<input type='hidden' name='To' value='" + to + "'>"
           + "<input type='hidden' name='Status' value='" + status + "'>"
           + "<input type='submit'></form>";
        $(form).submit();
    }
</script>
<div class="pageHeader">
    <div class="searchBar">
    <form id="pagerForm" onsubmit="return navTabSearch(this);"  action="<%= Request.RawUrl %>" method="post">
        
        <input type="hidden" name="pageNum" value="<%= PageNumber %>" />
        <input type="hidden" name="numPerPage" value="<%= PageSize %>" />

        <table class="searchContent" >
            <tr>
                <td>
                    <label><%= clsCmm.getTextValue("frm_inbox_txtProcess")%></label>
                    <select name="processName" id="processName">
                        <option value="">All</option>
                        <asp:repeater runat="server" ID="rptProcesses">
                            <ItemTemplate>
                                <option value="<%# Eval("PROCESSNAME").ToString().Trim() %>" <%# Eval("PROCESSNAME").ToString().Trim() == (ProcessSelectName ?? "").Trim() ? "selected" : "" %>><%# Eval("PROCESSNAME").ToString().Trim()%></option>
                            </ItemTemplate>
                        </asp:repeater>
                    </select>
                </td>
                <td>
                    <label><%= clsCmm.getTextValue("frm_inbox_txtIncidentFrom")%></label>
                    <input type="text" name="incidentNoFrom" id="from" size="8" value="<%:From %>" /> 至 
                    <input type="text" name="incidentNoTo" id="to" size="8" value="<%:To %>" />
                </td>
                <td>
                    <label><%= clsCmm.getTextValue("frm_initiate_gv_status")%></label>
                    <select name="status" id="status">
                        <option value="">All</option>
                        <option value="1" <%:Status == "1"?"selected":"" %>>成功</option>
                        <option value="0" <%:Status == "0"?"selected":"" %>>失败</option>
                    </select>
                </td>
            </tr>
        </table>
        <div class="subBar">
            <ul>
                <li>
                    <div class="buttonActive">
                        <div class="buttonContent">
                            <button type="submit">
                                <%=clsCmm.getTextValue("frm_inbox_btnSearch")%></button></div>
                    </div>
                </li>
            </ul>
        </div>
        </form>
    </div>
</div>
    <form id="form1" runat="server">
    <div class="pageContent">
    <div class="panelBar">
        <ul class="toolBar">
            <li>
                <a class="variables" href="javascript:void(0);" target="blank" onclick="ExportExel()">
                    <span>导出Exel</span>
                </a>
            </li>
        </ul>
    </div>
    <table class="table" width="100%" layouth="137">
        <thead>
            <tr>
                <th width="22">序号</th>
                <th width="200" align="center">流程名</th>
                <th width="60" align="center">实例号</th>
                <th width="100" align="center">干预事件</th>
                <th align="center">干预描述</th>
                <th width="180" align="center">操作人</th>
                <th width="120" align="center">操作时间</th>
                <th width="80" align="center">状态</th>
            </tr>
        </thead>
        <tbody>
            <asp:repeater id="rpt_ManagerLog" runat="server">
                <ItemTemplate>
                    <tr style="height: 25px;line-height: 25px;">
                        <td><%# Eval("序号")%></td>
                        <td><%# Eval("流程名")%></td>
                        <td><%# Eval("实例号")%></td>
                        <td><%# Eval("干预事件")%></td>
                        <td><%# Eval("干预描述")%></td>
                        <td><%# Eval("操作人")%></td>
                        <td><%# Eval("操作时间", "{0:yyyy-MM-dd HH:mm}")%></td>
                        <td><%# Eval("状态")%></td>
                    </tr> 
                </ItemTemplate>
            </asp:repeater>
        </tbody>
    </table>
    </div>
    <uc1:Pager ID="Pager1" runat="server" />
</form>
